From: Colin Walters Date: Fri, 14 Aug 2009 12:41:00 +0000 (-0400) Subject: Bug 582763 - Remove maximization effects X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~11078 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=f097304f3bbb574b90c3b7f8d2031dcb13d3b6e4;p=gnome-shell.git Bug 582763 - Remove maximization effects The maximize effect looked really ugly. In the absence of any cooler effects, none at all is better than what we have. Current compiz doesn't have one either. Note that in the future when we merge the frame into the panel in the maximize case, we may want an effect for that. --- diff --git a/js/ui/windowManager.js b/js/ui/windowManager.js index 946d9a31d..da03878c7 100644 --- a/js/ui/windowManager.js +++ b/js/ui/windowManager.js @@ -145,50 +145,13 @@ WindowManager.prototype = { }, _maximizeWindow : function(actor, targetX, targetY, targetWidth, targetHeight) { - if (!this._shouldAnimate(actor)) { - this._shellwm.completed_maximize(actor); - return; - } - - /* this doesn't work very well, as simply scaling up the existing - * window contents doesn't produce anything like the same results as - * actually maximizing the window. - */ - let scaleX = targetWidth / actor.width; - let scaleY = targetHeight / actor.height; - let anchorX = (actor.x - targetX) * actor.width/(targetWidth - actor.width); - let anchorY = (actor.y - targetY) * actor.height/(targetHeight - actor.height); - - actor.move_anchor_point(anchorX, anchorY); - - this._maximizing.push(actor); - Tweener.addTween(actor, - { scale_x: scaleX, - scale_y: scaleY, - time: WINDOW_ANIMATION_TIME, - transition: "easeOutQuad", - onComplete: this._maximizeWindowDone, - onCompleteScope: this, - onCompleteParams: [actor], - onOverwrite: this._maximizeWindowOverwrite, - onOverwriteScope: this, - onOverwriteParams: [actor] - }); + this._shellwm.completed_maximize(actor); }, _maximizeWindowDone : function(actor) { - if (this._removeEffect(this._maximizing, actor)) { - Tweener.removeTweens(actor); - actor.set_scale(1.0, 1.0); - actor.move_anchor_point_from_gravity(Clutter.Gravity.NORTH_WEST); - this._shellwm.completed_maximize(actor); - } }, _maximizeWindowOverwrite : function(actor) { - if (this._removeEffect(this._maximizing, actor)) { - this._shellwm.completed_maximize(actor); - } }, _unmaximizeWindow : function(actor, targetX, targetY, targetWidth, targetHeight) {